//
//  Color.m
//  Homework-04
//
//  Created by 岁变 on 16/7/7.
//  Copyright © 2016年 岁变. All rights reserved.
//

#import "Color.h"

@implementation Color

- (instancetype)initWithName:(NSString *)name value:(NSString *)value {
    self = [super init];
    if (self) {
        _name = name;
        _value = value;
    }
    return self;
}

+ (instancetype)colorWithName:(NSString *)name value:(NSString *)value {
    Color *color = [[Color alloc] initWithName:name value:value];
    return color;
}

- (NSString *)description {
    return [NSString stringWithFormat:@"colorName %@  colorValue %@", self.name, self.value];
}

@end
